package modler

import "gorm.io/gorm"

// 用户表
type User struct {
	gorm.Model
	Username string `gorm:"type:varchar(100)"`
	Password string `gorm:"type:varchar(100)"`
}

// 角色
type Rode struct {
	gorm.Model
	UserRode string `gorm:"type:varchar(100)"`
}

// 用户角色
type UserRode struct {
	gorm.Model
	Uid int `gorm:"type:int"`
	Rid int `gorm:"type:int"`
}

// 权限
type Node struct {
	gorm.Model
	RodeNode string `gorm:"type:varchar(100)"`
}

// 角色权限
type RodeNode struct {
	gorm.Model
	Rid int `gorm:"type:int"`
	Nid int `gorm:"type:int"`
}

// 商品
type Cope struct {
	gorm.Model
	CopeName  string `gorm:"type:varchar(100)"`
	CopesName string `gorm:"type:varchar(100)"`
}

// 订单
type Order struct {
	gorm.Model
	OrderHao   string `gorm:"type:varchar(100)"`
	OrderName  string `gorm:"type:varchar(100)"`
	OrdersName string `gorm:"type:varchar(100)"`
	OrderTime  string `gorm:"type:varchar(100)"`
	Pid        int    `gorm:"type:varchar(100)"`
}
